//数据库配置
const mysql = require(('mysql2'))
const db = mysql.createConnection({
    host: 'gz-cynosdbmysql-grp-rfjvskm5.sql.tencentcdb.com',
    port: '25077',
    user: 'root',
    password: 'root-hrm-0227',
    database: 'hrm-mysql'
});

db.connect(function (err) {
    if (err) {
        console.log('数据库连接失败，错误:' + err);
        return;
    }
    console.log('数据库连接成功!!!');
});

module.exports = db;